/*
 * Project Name demo
 * File Name ChatSessionDao
 * Package Name com.huxiaosu.demo.socketio.dao
 * Create Time 2023/1/31
 * Create by name：liujie
 */
package com.huxiaosu.demo.socketio.dao;

import com.huxiaosu.demo.socketio.entity.ChatSessionInfo;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

/**
 * Description
 *
 * @ClassName: ChatSessionDao
 * @author: liujie
 * @date: 2023/1/31 15:04
 */
public interface ChatSessionDao extends JpaSpecificationExecutor<ChatSessionInfo>, JpaRepository<ChatSessionInfo, String> {
    /**
     * 根据公告 ID+咨询人生成一条回话
     *
     * @param announcementId
     * @param investorId
     * @return com.huxiaosu.demo.socketio.entity.ChatSessionInfo
     * @author liujie
     * @date 2023/2/1 10:14
     */
    ChatSessionInfo findByAnnouncementIdAndInvestorId(Integer announcementId, Integer investorId);
}